package com.yc.Di.test.bean2;

import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Repository;

@Repository
//指定优先级,不修改业务层的代码,就可以实现不同的Dao实现类的注入
@Primary
public class OrderOceanDaoImpl implements OrderDao{
    @Override
    public void addOrder() {
        System.out.println("使用Ocean添加订单成功");
    }
}
